home *** CD-ROM | disk | FTP | other *** search
/ Champak 52 / Volume 52 - JOGO DISK .iso / Games / dancing_princess.swf / scripts / frame_5 / DoAction.as
Text File  |  2007-09-26  |  2KB  |  85 lines

  1. stop();
  2. replay_bt.onRollOver = function()
  3. {
  4.    so1.start(0,1);
  5.    this._xscale = 105;
  6.    this._yscale = 105;
  7. };
  8. replay_bt.onRollOut = function()
  9. {
  10.    this._xscale = 100;
  11.    this._yscale = 100;
  12. };
  13. replay_bt.onPress = function()
  14. {
  15.    so1.start(0,1);
  16.    this.gotoAndStop(2);
  17. };
  18. replay_bt.onRelease = function()
  19. {
  20.    this.gotoAndStop(1);
  21.    gotoAndStop(4);
  22. };
  23. replay_bt.onReleaseOutside = function()
  24. {
  25.    this.gotoAndStop(1);
  26.    gotoAndStop(4);
  27. };
  28. ava_dress_applay = function()
  29. {
  30.    var _loc4_ = 0;
  31.    while(_loc4_ < m_name.length)
  32.    {
  33.       var _loc3_ = _root[m_name[_loc4_] + "_dname"].indexOf("_");
  34.       _root.game_ava[m_name[_loc4_] + "_m"].gotoAndStop(parseInt(_root[m_name[_loc4_] + "_dname"].slice(_loc3_ + 1,_loc3_ + 3)) + 2);
  35.       trace(m_name[_loc4_] + "_m" + "  : stop=" + parseInt(_root[m_name[_loc4_] + "_dname"].slice(_loc3_ + 1,_loc3_ + 3) + 2));
  36.       _loc4_ = _loc4_ + 1;
  37.    }
  38.    _loc4_ = 0;
  39.    while(_loc4_ < 12)
  40.    {
  41.       var _loc2_ = 0;
  42.       while(_loc2_ < m_name.length)
  43.       {
  44.          _root[m_name[_loc2_] + "_" + _loc4_].removeMovieClip();
  45.          _loc2_ = _loc2_ + 1;
  46.       }
  47.       _loc4_ = _loc4_ + 1;
  48.    }
  49. };
  50. give_score = function()
  51. {
  52.    so3.start(0,1);
  53.    if(one_dname == "")
  54.    {
  55.       if(up_dname == "" || down_dname == "")
  56.       {
  57.          ending_score.gotoAndStop(4);
  58.       }
  59.       else
  60.       {
  61.          ending_score.gotoAndStop(random(3) + 1);
  62.       }
  63.    }
  64.    else
  65.    {
  66.       ending_score.gotoAndStop(random(3) + 1);
  67.    }
  68.    game_ava.ava_face.gotoAndStop(ending_score._currentframe + 1);
  69.    if(up_dname != "")
  70.    {
  71.       game_ava.underwear_up._visible = false;
  72.    }
  73.    if(down_dname != "")
  74.    {
  75.       game_ava.underwear_down._visible = false;
  76.    }
  77.    if(one_dname != "")
  78.    {
  79.       game_ava.underwear_up._visible = false;
  80.       game_ava.underwear_down._visible = false;
  81.    }
  82. };
  83. give_score();
  84. ava_dress_applay();
  85.